package demo1;

import java.sql.SQLOutput;
import java.util.ArrayList;

public class String1 {
    //删除两个字符串中相同的字符
    public static void main(String[] args){
        String s1="welcome to";
        String s2="come";
        ArrayList<Character> list=new ArrayList<>();
        for(int i=0;i<s1.length();i++){
            char c=s1.charAt(i);
            if(!s2.contains(c+"")){
                list.add(c);
            }
        }
        System.out.print(list);
    }
}
